﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace PetriNetSharp.Controller
{
	/// <summary>
	/// Delegate for when a controller is invalidated
	/// </summary>
	/// <param name="controller">The controller that was invaldiated</param>
	public delegate void ControllerInvalidatedEventHandler(IControllerInvalidatable controller);
	
	/// <summary>
	/// Interface for controllers that can be invalidated
	/// </summary>
	public interface IControllerInvalidatable
	{
		/// <summary>
		/// Occurs when the controller is invalidated
		/// </summary>
		event ControllerInvalidatedEventHandler Invalidated;

		/// <summary>
		/// Invalidate this controller
		/// </summary>
		void Invalidate();
	}
}
